package com.rongxue.mapper;

import com.rongxue.pojo.SProject;
import com.rongxue.pojo.SProjectExample;
import com.rongxue.pojo.SProjectWithBLOBs;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

public interface SProjectMapper {
    int countByExample(SProjectExample example);

    int deleteByExample(SProjectExample example);

    int deleteByPrimaryKey(Long id);

    int insert(SProjectWithBLOBs record);

    int insertSelective(SProjectWithBLOBs record);

    List<SProjectWithBLOBs> selectByExampleWithBLOBs(SProjectExample example);

    List<SProject> selectByExample(SProjectExample example);

    SProjectWithBLOBs selectByPrimaryKey(Long id);

    int updateByExampleSelective(@Param("record") SProjectWithBLOBs record, @Param("example") SProjectExample example);

    int updateByExampleWithBLOBs(@Param("record") SProjectWithBLOBs record, @Param("example") SProjectExample example);

    int updateByExample(@Param("record") SProject record, @Param("example") SProjectExample example);

    int updateByPrimaryKeySelective(SProjectWithBLOBs record);

    int updateByPrimaryKeyWithBLOBs(SProjectWithBLOBs record);

    int updateByPrimaryKey(SProject record);

    //根据状态查询出标的信息
    List<SProject> selectProjectStatus(@Param("record") String record);

    SProject selectProjectById(String projectId);

    //更新标的状态
    int updateProjectStatusByprojectId(@Param("status") String status, @Param("projectId") String projectId);

    //更新交易流水号
    int updateProjectNumber(@Param("refnumberId") String refnumberId, @Param("projectId") String projectId);

    void updateByProjectId(SProjectWithBLOBs project);

    SProject selectProjectInfo(Long projectId);
    //查询生效中的标
    List<SProject>  selectProjectList ();
    //产品列表
    List<SProject> selectProjectListByStatus();
    //产品列表2
    List<SProject> selectProjectListByStatus2(Integer status);
    //项目资料详情
    SProject  selectProjectByPid (String id);
    //项目资料详情2
    SProject selectProjectDetailByPid(String id);
    //查询项目全部信息
    SProject selectProjectAllById(String id);
    //产品投资列表
    List<SProject> selectProjectInvestList(String pid);
    //用户投资
    List<SProject> selectUserInvestList(Map<String,Object> map);
    //投资详情
    SProject selectInvestmentDetails(String id);

    SProject  selectProjectListLevel1();

    SProject selectProjectListLevel2();

    //合同所需的数据
    SProject selectByUserDueDetailId(String dueId);

}